using System;
using System.Collections.Generic;
using System.Text;
using Pixysoft.Framework.Noebe.Orm;

namespace Pixysoft.Framework.Security.Entity
{
    public interface User
    {
        [OrmPrimaryKey]
        string UserName { get;set;}

        string Pwd { get;set;}
        bool IsAvailable { get;set;}
        bool IsInnerUser { get;set;}
        bool IsSuperUser { get;set;}


        List<Role> RoleList { get;set;}
        List<Group> GroupList { get;set;}

        List<PageRole> PageRoleList { get;set;}
        List<PageGroup> PageGroupList { get;set;}



        void AddToRoleList(params Role[] values);
        void AddToGroupList(params Group[] values);
        void AddToPageRoleList(params PageRole[] values);
        void AddToPageGroupList(params PageGroup[] values);



        void RemoveFromRoleList(params Role[] values);
        void RemoveFromGroupList(params Group[] values);
        void RemoveFromPageRoleList(params PageRole[] values);
        void RemoveFromPageGroupList(params PageGroup[] values);



        Role SelectRoleList(object upk);
        Group SelectGroupList(object upk);
        PageRole SelectPageRoleList(object upk);
        PageGroup SelectPageGroupList(object upk);
    }
}
